package com.xiaohe66.web.domain.im.value;

import com.xiaohe66.web.domain.account.value.AccountId;
import com.xiaohe66.web.integration.domain.LongValue;
import com.xiaohe66.web.integration.domain.ValueObject;
import lombok.Data;
import lombok.EqualsAndHashCode;
import lombok.NonNull;

/**
 * @author xiaohe
 * @since 2023.09.08 16:23
 */
@EqualsAndHashCode
@Data
public class MessageUnread implements ValueObject {

    @NonNull
    private final AccountId createId;

    @NonNull
    private final LongValue qty;

    @NonNull
    private final MessageId lastId;

    @Override
    public String toString() {
        return "MessageUnread(" + createId.getValue() + ":" + qty.getValue() + "," + lastId.getValue() + ")";
    }
}
